package com.bluesword.monster.countdownwidget;

import android.support.v7.app.AppCompatActivity;
import android.os.Bundle;

import com.bluesword.monster.countdownwidget.widget.CountDownLinearLayout;

import java.text.SimpleDateFormat;
import java.util.Calendar;
import java.util.Date;

public class MainActivity extends AppCompatActivity {

    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_main);




        CountDownLinearLayout layout= (CountDownLinearLayout) findViewById(R.id.countDownWidget);
        Calendar calendar = Calendar.getInstance();
        calendar.add(calendar.DATE,1);//明天之后结束
        layout.startCountDown(calendar.getTimeInMillis()/1000);

    }
}
